home *** CD-ROM | disk | FTP | other *** search
- /*****************************************************************************/
- /*
- FXTKEYS.CB - BRIEF MACRO AUTOLOAD AND KEY ASSIGNMENT FOR
-
- FFTN (TM) FORTRAN FUNCTION TREE NAVIGATOR
-
- Copyright (C) Juergen Mueller (J.M.) 1992-1996
- All rights reserved.
-
- You are expressly prohibited from selling this software in any form,
- distributing it with another product, or removing this notice.
-
- Limited permission is given to registered FXT users to modify this
- file for their own personal use only. This file may not be used for any
- purpose other than in conjunction with the FXT software package.
-
- THIS SOFTWARE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
- EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, THE
- IMPLIED WARRANTIES OF MERCHANTIBILITY OR FITNESS FOR A PARTICULAR
- PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
- PROGRAM AND DOCUMENTATION IS WITH YOU.
-
- written by: Juergen Mueller, Aldingerstrasse 22, D-70806 Kornwestheim,
- GERMANY
-
- FILE : FXTKEYS.CB
- REVISION : 27-Apr-1996
- 18:31:15
- */
- /*****************************************************************************/
-
- /*****************************************************************************/
- /* INITIALIZATION */
- /*****************************************************************************/
- void _init(void)
- {
- /* Perform autoload of the macro file FXT [.CM] for the following macros. */
- /* The macro file must be in the default BRIEF macro directory, */
- /* otherwise the complete path must be specified here within "autoload()" */
- autoload("fxt", "fft",
- "fftfind",
- "fftmenu",
- "fftbase",
- "fftfilemenu",
- "fxtsearchxref",
- "fftxrefmenu",
- "fftxrefmenuagain",
- "fftdefmenu"
- );
-
- /* Assign keys to the available macro functions to simplify working */
- /* if these key combinations are already used, switch to other ones */
-
- /**** FFT functions ****/
- /* SHIFT + <key> */
- assign_to_key("<Shift-F1>", "fft");
- assign_to_key("<Shift-F2>", "fftmenu");
- assign_to_key("<Shift-F3>", "fftxrefmenu");
- assign_to_key("<Shift-F4>", "fftxrefmenuagain");
- assign_to_key("<Shift-F7>", "fftdefmenu");
- assign_to_key("<Shift-F8>", "fftfilemenu");
- assign_to_key("<Shift-F11>", "fftfind");
- assign_to_key("<Shift-F12>", "fftbase");
-
- /* CTRL + <key> */
- assign_to_key("<Ctrl-Tab>", "fxtsearchxref");
- }
-
- /*****************************************************************************/
- /* HELP-information */
- /*****************************************************************************/
- void fxthelp(void)
- {
- int help_buf, old_buf;
-
- old_buf = inq_buffer(); /* remember actual buffer */
- help_buf = create_buffer("HELP", "HELP");
- set_buffer(help_buf); /* make actual buffer */
- attach_buffer(help_buf); /* attach new buffer to window */
- top_of_buffer(); /* go to top */
-
- insert("FXT HELP INFORMATION\n\n");
-
- insert("Complete list of all available macro functions with assigned key-combination\n");
- insert("and macro-name. For more informations see the FFT documentation.\n\n");
-
- insert("FFT macro functions\n");
- insert("<Shift-F1> fft\n");
- insert("<Shift-F2> fftmenu\n");
- insert("<Shift-F3> fftxrefmenu\n");
- insert("<Shift-F4> fftxrefmenuagain\n");
- insert("<Shift-F7> fftdefmenu\n");
- insert("<Shift-F8> fftfilemenu\n");
- insert("<Shift-F11> fftfind\n");
- insert("<Shift-F12> fftbase\n");
-
- insert("\nAdditional macro function\n");
- insert("<Ctrl-Tab> fxtsearchxref\n");
- insert("\nThis help screen is invoked by macro 'fxthelp'.\n");
-
- insert("\npress RETURN to continue");
- refresh(); /* update new screen */
-
- while ((read_char() & 0xff) != 13) /* wait for RETURN key pressed */
- ;
-
- set_buffer(old_buf); /* restore old buffer */
- attach_buffer(old_buf); /* attach old buffer to window */
- delete_buffer(help_buf); /* delete buffer from list */
- }
-
- /**** THIS IS THE END THIS IS THE END THIS IS THE END THIS IS THE END ****/
-